﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.ComponentModel.DataAnnotations;

namespace Blog.Models
{
    public class ArticleCreateViewModel
    {
        public int ID { get; set; }

        [Required(ErrorMessage="Le titre est requis")]
        public string Title { get; set; }

        [Required(ErrorMessage="Le contenu est requis")]
        public string Content { get; set; }

        [Required(ErrorMessage="Veuillez choisir une categorie")]
        public int CategoryID { get; set; }

        public IEnumerable<DAL.Category> Category{ get; set; }
    }
}